<!DOCTYPE html>
<html>
  <head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width,initial-scale=1,user-scalable=0">
    <title>my-light-demo</title>
    <script src="https://h5itest1.dfzq.com.cn/open/app/js/jquery.js?v=2849239b95"></script>
    <script src="https://h5itest1.dfzq.com.cn/open/app/js/lightsdk.umd.js"></script>
  </head>
  <body>
    <button id="btnSetTitle">点击设置标题</button>
  </body>
  <!-- 引入 VConsole CDN 链接 -->
  <script src="https://h5itest1.dfzq.com.cn/open/app/js/vconsole.min.js?v=e637889f2f"></script>
  <script>
    var vConsole = new window.VConsole();
  </script>
  <script>
    $(function() {
      $('#btnSetTitle').click(function() {
        window.LightSDK.native.setTitle({
          title: '测试标题'
        });

        window.LightSDK.native.removeButton({
            "position": "right"
        });

        window.LightSDK.native.addButton({
            "title": "测试按钮",
            "position": "right",
            "action": function() {
                console.log("点击了测试按钮");
            }
        });
      })
    })
  </script>
</html>